# Maintainer: Alexey Pavlov <alexpux@gmail.com>

pkgname=icon-naming-utils
pkgver=0.8.90
pkgrel=1
pkgdesc="Maps the new names of icons for Tango to the legacy names used by the GNOME and KDE desktops"
arch=('i686' 'x86_64')
license=('GPL')
url="http://tango.freedesktop.org/"
depends=('perl-XML-Simple')
source=(http://tango.freedesktop.org/releases/${pkgname}-${pkgver}.tar.gz
        remove-legacy-calc.patch)
md5sums=('2c5c7a418e5eb3268f65e21993277fba'
         'd3490e31df95ae11c96f0af2a9ef2ed0')

prepare() {
  cd ${srcdir}/${pkgname}-${pkgver}
  patch -Np1 -i "${srcdir}/remove-legacy-calc.patch"
}

build() {
  cd ${srcdir}/${pkgname}-${pkgver}
  ./configure \
    --prefix=/usr \
    --build=${CHOST} \
    --host=${CHOST} \
    --sysconfdir=/usr/etc \
    --libexecdir=/usr/lib/icon-naming-utils \
    --localstatedir=/var
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
}
